package com.xiyu.service.vo.material.transfer;

import com.xiyu.service.vo.material.order.baseVO.MaterialTransferBase;
import com.xiyu.service.vo.material.order.baseVO.MaterialTransferDetailBase;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import java.util.*;
import jakarta.validation.constraints.*;
import org.hibernate.validator.constraints.Length;
import jakarta.validation.Valid;
import com.xiyu.service.enums.common.CommonStatusEnum;
import com.xiyu.service.framework.validation.InEnum;
import java.math.BigDecimal;

@Schema(description = "新增调拨单")
@Data
public class TransferCreateInput extends MaterialTransferBase {

    @Schema(description = "物资调拨明细")
    @Valid
    private List<detail> details;

    @Schema(description = "物资调拨明细")
    @Data
    @Valid
    public static class detail extends MaterialTransferDetailBase {

        @Schema(description = "数量")
        @Positive(message = "数量必须大于0")
        @NotNull(message = "数量不能为空")
        @Digits(integer = 13, fraction = 4, message = "数量格式无效")
        private BigDecimal number;
    }

}